//
//  DDBossCommunicatedCattleViewController.m
//  DingDongZP
//
//  Created by Jyh on 16/4/27.
//  Copyright © 2016年 iyhjiang.com. All rights reserved.
//

#import "DDBossCommunicatedCattleViewController.h"
#import "DDCommunicatedStore.h"
#import "DDDiscoverJobFinderCell.h"
#import "DDJobfinderDetailViewController.h"

@implementation DDBossCommunicatedCattleViewController


- (void)viewDidLoad
{
    [super viewDidLoad];
    self.title = @"沟通过的牛人";
    self.tableView.rowHeight = HEIGHT_DISCOVER_CELL;
    self.tableView.contentInset = UIEdgeInsetsMake(7, 0, 7, 0);
    self.dataSource = [NSMutableArray arrayWithArray:[[DDCommunicatedStore sharedStore] communicatedCattles]];
    self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
    [self.tableView reloadData];
    
}

- (void)viewWillAppear:(BOOL)animated {
    
    [super viewWillAppear:animated];
    [self.rdv_tabBarController setTabBarHidden:true animated:true];
}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{

    LDBossRecJobFinderCell *cell = [tableView dequeueReusableCellWithIdentifier:@"jonfinderscommunicatecell"];
    if (cell == nil) {
        
        cell = [[LDBossRecJobFinderCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:@"jonfinderscommunicatecell"];
    }
    
    cell.models = (DDJobfinderDetail *)self.dataSource[indexPath.row];
    return cell;
    
}

- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath
{
    LDJobfinderDetailBaseVCInAll_Show *vc = [[LDJobfinderDetailBaseVCInAll_Show alloc] init];
//    LDJobfinderDetailBaseVC *vc = [[LDJobfinderDetailBaseVC alloc] init];
    
    DDJobfinderDetail *model = [self.dataSource objectAtIndex:indexPath.row];
    vc.userID = model.userid;
//    vc.hidesBottomBarWhenPushed = YES;
    [self.navigationController pushViewController:vc animated:YES];
}


@end
